from flask import Flask

app = Flask(__name__)


@app.route("/")
def index():
    return f"<h1>这里是首页</h1>"


# @app.route("/detail/<bid>/")
@app.route("/detail/<int:bid>/")
def detail(bid):
    print(type(bid))
    return f"<h1>这里是详情{bid}</h1>"


@app.route("/media/<path:path>/")
def media(path):
    print(type(path))
    return f"你访问的资源是{path}"


def main():
    app.run(debug=True)


if __name__ == '__main__':
    main()
